package es.cazadoresmadridejos.model;

import java.math.BigDecimal;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;

@Entity(name="Reason")
@Table(name="temporada")
public class Reason extends BaseEntity {

	private Long year;
	private BigDecimal hunter;//cuota_escopetero;
	private BigDecimal hunterRetired;//cuota_escopetero_jubilado;
	private BigDecimal greyhoundMan;//cuota_galguero;
	private BigDecimal greyhoundManRetired;//cuota_galguero_jubilado;
	private BigDecimal onlyBirds;//cuota_solo_zorzales;
	private BigDecimal deerAssistance;//cuota_solo_zorzales;
	private BigDecimal deer;//cuota_solo_zorzales;
	private BigDecimal male;//cuota_solo_zorzales;
	private BigDecimal manteinaceGreyhounMan;//cuota_solo_zorzales;
	private BigDecimal manteinaceHunter;//cuota_solo_zorzales;
	private BigDecimal changeShootgunToGreyhound;//cuota_solo_zorzales;
	private BigDecimal initGreyhoundMan;//cuota_solo_zorzales;
	private BigDecimal initHunter;//cuota_solo_zorzales;
	private BigDecimal others;//Multas y demas
	private String othersDescription;
	
	public Reason(long id) {
		super.setId(id);
	}
	public Reason() {
		super();
	}
	@Column(unique=true)
	public Long getYear() {
		return year;
	}
	public void setYear(Long year) {
		this.year = year;
	}
	@Column(name="cuota_escopetero")
	public BigDecimal getHunter() {
		return hunter;
	}
	public void setHunter(BigDecimal hunter) {
		this.hunter = hunter;
	}
	@Column(name="cuota_escopetero_jubilado")
	public BigDecimal getHunterRetired() {
		return hunterRetired;
	}
	public void setHunterRetired(BigDecimal hunterRetired) {
		this.hunterRetired = hunterRetired;
	}
	@Column(name="cuota_galguero")
	public BigDecimal getGreyhoundMan() {
		return greyhoundMan;
	}
	public void setGreyhoundMan(BigDecimal greyhoundMan) {
		this.greyhoundMan = greyhoundMan;
	}
	@Column(name="cuota_galguero_jubilado")
	public BigDecimal getGreyhoundManRetired() {
		return greyhoundManRetired;
	}
	public void setGreyhoundManRetired(BigDecimal greyhoundManRetired) {
		this.greyhoundManRetired = greyhoundManRetired;
	}
	@Column(name="cuota_solo_zorzales")
	public BigDecimal getOnlyBirds() {
		return onlyBirds;
	}
	public void setOnlyBirds(BigDecimal onlyBirds) {
		this.onlyBirds = onlyBirds;
	}
	@Column(name="cuota_asistencia_corzo")
	public BigDecimal getDeerAssistance() {
		return deerAssistance;
	}
	public void setDeerAssistance(BigDecimal deerAssistance) {
		this.deerAssistance = deerAssistance;
	}
	@Column(name="cuota_cobro_corzo")
	public BigDecimal getDeer() {
		return deer;
	}
	public void setDeer(BigDecimal deer) {
		this.deer = deer;
	}
	@Column(name="cuota_macho_perdiz")
	public BigDecimal getMale() {
		return male;
	}
	public void setMale(BigDecimal male) {
		this.male = male;
	}
	@Column(name="cuota_mantenimiento_galguero")
	public BigDecimal getManteinaceGreyhounMan() {
		return manteinaceGreyhounMan;
	}
	public void setManteinaceGreyhounMan(BigDecimal manteinaceGreyhounMan) {
		this.manteinaceGreyhounMan = manteinaceGreyhounMan;
	}
	@Column(name="cuota_mantenimiento_escopetero")
	public BigDecimal getManteinaceHunter() {
		return manteinaceHunter;
	}
	public void setManteinaceHunter(BigDecimal manteinaceHunter) {
		this.manteinaceHunter = manteinaceHunter;
	}
	@Column(name="cuota_cambio_galgos_escopeta")
	public BigDecimal getChangeShootgunToGreyhound() {
		return changeShootgunToGreyhound;
	}
	public void setChangeShootgunToGreyhound(BigDecimal changeShootgunToGreyhound) {
		this.changeShootgunToGreyhound = changeShootgunToGreyhound;
	}
	@Column(name="cuota_entrada_galguero")
	public BigDecimal getInitGreyhoundMan() {
		return initGreyhoundMan;
	}
	public void setInitGreyhoundMan(BigDecimal initGreyhoundMan) {
		this.initGreyhoundMan = initGreyhoundMan;
	}
	@Column(name="cuota_entrada_escopetero")
	public BigDecimal getInitHunter() {
		return initHunter;
	}
	public void setInitHunter(BigDecimal initHunter) {
		this.initHunter = initHunter;
	}
	@Column(name="otros")
	public BigDecimal getOthers() {
		return others;
	}
	public void setOthers(BigDecimal others) {
		this.others = others;
	}
	@Column(name="descripcion_otros")
	public String getOthersDescription() {
		return othersDescription;
	}
	public void setOthersDescription(String othersDescription) {
		this.othersDescription = othersDescription;
	}
	
	@Transient
	public String getViewYear(){
		return year.toString().substring(0, 4)  + "-" + year.toString().substring(4);
	}
	@Transient
	public String getStartYear(){
		return year.toString().substring(0, 4);
	}
	@Transient
	public String getEndYear(){
		return year.toString().substring(4);
	}
	
}
